package com.yunlongn.async.function;

public abstract class RetryActionAdapter<T> implements RetryScheduleAction<T>{

    private RetryScheduleAction<T> action;

    public RetryActionAdapter(RetryScheduleAction<T> action) {
        this.action = action;
    }

    @Override
    public String getParamType() {
        return action.getParamType();
    }

    @Override
    public T getParam() {
        return action.getParam();
    }

    @Override
    public String getTaskName() {
        return action.getTaskName();
    }

    @Override
    public boolean execute(T param) {
        return action.execute(param);
    }

    @Override
    public void onFail() {
        action.onFail();
    }
}
